package com.master.chat.gpt.pojo.entity;

import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.master.chat.framework.base.BaseEntity;
import lombok.*;
import lombok.experimental.Accessors;

import java.math.BigDecimal;
import java.time.LocalDateTime;

;

/**
 * 订单对象 gpt_order
 *
 * @author: Yang
 * @date: 2023-04-28
 * @version: 1.0.0
 * Copyright Ⓒ 2023 Master Computer Corporation Limited All rights reserved.
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = true)
@TableName("gpt_order")
public class Order extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /**
     * 支付成功时间
     */
    private LocalDateTime successTime;

    /**
     * 订单号
     */
    private String tradeNo;

    /**
     * 渠道交易ID
     */
    private String transactionId;

    /**
     * 下单用户
     */
    private Long userId;

    /**
     * 购买套餐
     */
    private Long combId;

    /**
     * 价格
     */
    private BigDecimal price;

    /**
     * 支付渠道 1 微信小程序 2、微信公众号 3、微信h5 4、微信扫码
     */
    private Integer chanel;

    /**
     * 订单状态 1 待支付 2 支付成功 3 支付超时 4 已退款
     */
    private Integer status;

    /**
     * 是否删除 0->未删除;1->已删除
     */
    @TableLogic
    private Integer deleted;

}
